package com.freejava.test_websocket.service;

import org.springframework.stereotype.Service;

@Service
public class ChatService {

    public boolean isValidUserName(String username) {
        if (username.length() > 20 || username.length() < 2) {
            return false;
        }
        return true;
    }


    public boolean isValidPassword(String password) {
        if (password.length() > 12 || password.length() < 6) {
            return false;
        }
        return true;
    }

}
